package cn.gcjxsc.consts;

/**
 * 提现类型.
 *
 * @author pumbaa
 * @since 1.0
 */
public enum WithdrawType {
    /**
     * 普通会员提现
     */
    MEMBER,
    /**
     * 业务员提现
     */
    SALESMAN,
    /**
     * 商户提现
     */
    MERCHANT;

    public static WithdrawType fromCode(String code) {
        if (code.equalsIgnoreCase(MERCHANT.name())) {
            return MERCHANT;
        }
        else if (code.equalsIgnoreCase(SALESMAN.name())) {
            return SALESMAN;
        }
        else {
            return MEMBER;
        }
    }
}
